package com.ics.cmsadmin.modules.basic.bean;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.ics.cmsadmin.frame.converter.serializer.Date2LongStringSerializer;
import com.ics.cmsadmin.frame.converter.serializer.LongString2DataDeserializer;
import com.ics.cmsadmin.modules.sso.LoginInfo;
import lombok.Builder;
import lombok.Data;
import lombok.experimental.Tolerate;

import java.util.Date;

@Data
@Builder
public class StudentBean extends LoginInfo {
    // 用户id
    private String id;
    // 用户名
    private String username;
    // 真实名字
    private String realName;
    // 头像
    private String avatar;
    // 手机号
    private String phone;
    // 生日
    private String birthday;
    // 性别
    private String gender;
    // 用户微信公众号openid
    private String openId;
    private String accessToken;
    // 微信unionid
    private String unionId;
    // 昵称,默认时微信昵称
    private String nickname;
    // 登陆密码
    private String password;
    // 创建时间
    @JsonSerialize(using = Date2LongStringSerializer.class)
    @JsonDeserialize(using = LongString2DataDeserializer.class)
    private Date createTime;
    // 修改时间
    @JsonSerialize(using = Date2LongStringSerializer.class)
    @JsonDeserialize(using = LongString2DataDeserializer.class)
    private Date updateTime;
    // 账号状态 1
    private Boolean isActive;
    //是否关注
    private Boolean isFollowed;
    // 特殊vip用户 0
    private Boolean specialVip;
    // 分销商编号
    private String agentNo;

    private String startCreateTime;
    private String endCreateTime;
    private String salesman;
    private String registerSource;  // 只能是 wechat, ios, android
    @Tolerate
    public StudentBean () {}

}
